#include "list.h"


int main(int argc, char **argv) {
    
  list *my_list = new_list();
  
  // Adding new element in the list
  add_element(my_list, "java");
  add_element(my_list, "python");
  add_element(my_list, "c#");
  add_element(my_list, "perl");
  add_element(my_list, "php");
  
  printf("Printing the list:\n");
  print_list(my_list);
  
  printf("The perl language is in the list? %s\n", has_element(my_list, "perl") ? "TRUE" : "FALSE");
  printf("The hasckell language is in the list? %s\n", has_element(my_list, "hasckell") ? "TRUE" : "FALSE");
  printf("The php language is in the list? %s\n", has_element(my_list, "php") ? "TRUE" : "FALSE");
  
  printf("Removing 'python' element.\n");
  remove_element(my_list, "python");
  
  printf("Printing list after deletion\n");
  print_list(my_list);
  
  printf("Cleaning memory.\n");
  free_list(my_list);
  
  return 0;
}
